package idv.cjcat.pyronova.nodes {
	import flash.geom.ColorTransform;
	import idv.cjcat.pyronova.render.Graphics;
	import idv.cjcat.pyronova.render.RenderVisitor;
	
	public class TransformColor extends Node {
		
		public var transform:ColorTransform;
		
		public function TransformColor(transform:ColorTransform = null) {
			this.transform = transform;
		}
		
		private var g:Graphics;
		override public function render(visitor:RenderVisitor):void {
			g = visitor.graphics();
			g.topBuffer().colorTransform(g.rect(), transform);
		}
	}
}